home *** CD-ROM | disk | FTP | other *** search
/ CU Amiga Super CD-ROM 18 / CU Amiga Magazine's Super CD-ROM 18 (1997)(EMAP Images)(GB)[!][issue 1998-01].iso / CUCD / Programming / ModemLink / Source / Modem.h < prev    next >
C/C++ Source or Header  |  1997-03-25  |  2KB  |  73 lines

  1. /*
  2. ** NAME: Modem.h
  3. */
  4.  
  5. #ifndef MODEM_H
  6. #define MODEM_H
  7.  
  8. #include <exec/types.h>
  9. #include <devices/serial.h>
  10. #include <utility/tagitem.h>
  11.  
  12. /*
  13. ** Tags to be used with ML_SendModemCMD()
  14. */
  15. #define ML_DUMMY             (TAG_USER + 0x1000)
  16.  
  17. #define ML_DialTime          (ML_DUMMY + 0x00)
  18. #define ML_AnswerTime        (ML_DUMMY + 0x01)
  19. #define ML_DialPrefix        (ML_DUMMY + 0x02)
  20. #define ML_Suffix            (ML_DUMMY + 0x03)
  21. #define ML_OkText            (ML_DUMMY + 0x04)
  22. #define ML_BusyText          (ML_DUMMY + 0x05)
  23. #define ML_NoCarrierText     (ML_DUMMY + 0x06)
  24. #define ML_NoDialText        (ML_DUMMY + 0x07)
  25. #define ML_AutoAnsText       (ML_DUMMY + 0x08)
  26.  
  27.  
  28. /*
  29. ** Return codes for the SendModemCMD() & Dial routine
  30. ** Note that most of these corresponde to what the modem itself
  31. ** would return.  However, the MODEM_CONNECT is returned when
  32. ** the Carrier Detect (CD) bit is set in serial device status bits.
  33. ** The MODEM_TIMEOUT is set when none of the other results codes
  34. ** occured in the specified amount of time for that command.
  35. */
  36. #define MODEM_OK              0x0000
  37. #define MODEM_ERROR           0x0001
  38. #define MODEM_BUSY            0x0002
  39. #define MODEM_NOCARRIER       0x0003
  40. #define MODEM_NODIAL          0x0004
  41. #define MODEM_OFF             0x0005
  42. #define MODEM_CONNECT         0x0010
  43. #define MODEM_TIMEOUT         0x0011
  44.  
  45.  
  46. /*
  47. ** Prototypes
  48. */
  49. ULONG __saveds __asm
  50. ML_SendModemCMDTagList
  51. (
  52.   register __a0 struct IOExtSer *SerIO,
  53.   register __a1 char *CMD,
  54.   register __a2 struct TagItem *tagList
  55. );
  56.  
  57. ULONG __saveds __asm
  58. ML_DialTagList
  59. (
  60.   register __a0 struct IOExtSer *SerIO,
  61.   register __a1 char *PhoneNum,
  62.   register __a2 struct TagItem *tagList
  63. );
  64.  
  65. ULONG __saveds __asm
  66. ML_AnswerTagList
  67. (
  68.   register __a0 struct IOExtSer *SerIO,
  69.   register __a1 struct TagItem *tagList
  70. );
  71.  
  72. #endif
  73.